/*
 * Copyright 2022-2029 heshuixing(https://gitee.com/heshuixing)
 *
 * Licensed under the Apache License, Version 2.0 (the "License");
 * you may not use this file except in compliance with the License.
 * You may obtain a copy of the License at
 *
 *     http://www.apache.org/licenses/LICENSE-2.0
 *
 * Unless required by applicable law or agreed to in writing, software
 * distributed under the License is distributed on an "AS IS" BASIS,
 * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
 * See the License for the specific language governing permissions and
 * limitations under the License.
 */
package com.mercury.ec.framework.air.core.client.dto.order.issue;

import com.mercury.ec.framework.air.core.client.validator.AirClientGroup;
import com.mercury.ec.framework.common.validation.InEnum;
import com.mercury.ec.module.basic.enums.BasicBizScopeTypeEnum;
import io.swagger.v3.oas.annotations.media.Schema;
import lombok.Data;

import javax.validation.constraints.NotBlank;
import javax.validation.constraints.NotNull;
import java.math.BigDecimal;
import java.time.LocalDate;

/**
 * 机票订单出票 Request DTO
 *
 * @author hesx
 */
@Data
@Schema(description = "管理后台 - 订单出票 Request VO")
public class AirOrderIssueReqDTO {

    @Schema(description = "渠道编号", requiredMode = Schema.RequiredMode.REQUIRED, example = "102")
    @NotNull(message = "渠道编号不能为空")
    private Long channelId;

    @Schema(description = "业务类型 字典（basic_biz_scope_type 1-国内/2-国际）", requiredMode = Schema.RequiredMode.REQUIRED, example = "1")
    @InEnum(value = BasicBizScopeTypeEnum.class, message = "机票类型必需是【1-国内/2-国际】")
    @NotNull(message = "机票业务类型不能为空", groups = {AirClientGroup.Sunstn.class})
    private Integer scopeType;

    @Schema(description = "订座编码", requiredMode = Schema.RequiredMode.REQUIRED, example = "123456")
    @NotBlank(message = "订座编码不能为空", groups = {AirClientGroup.Sunstn.class})
    private String pnr;

    @Schema(description = "office号", requiredMode = Schema.RequiredMode.REQUIRED, example = "123456")
    @NotBlank(message = "office号不能为空", groups = {AirClientGroup.Sunstn.class})
    private String officeNo;

    @Schema(description = "票价级别FareBasis", example = "ZPR7WNNP")
    private String fareBasis;

    @Schema(description = "客户协议号")
    private String customerAgreementNo;

    @Schema(description = "打票机号", requiredMode = Schema.RequiredMode.REQUIRED, example = "123456")
    @NotBlank(message = "打票机号不能为空", groups = {AirClientGroup.Sunstn.class})
    private String ticketVendingMachineNo;

    @Schema(description = "卡号", example = "6222020000000000000")
    private String cardNo;

    @Schema(description = "卡有效期", example = "2022-01-01")
    private LocalDate cardNoValidDate;

    @Schema(description = "订单金额", example = "123456")
    private BigDecimal amount;






//    @Schema(description = "预定参数加密串（白屏来源订单必填）", requiredMode = Schema.RequiredMode.REQUIRED, example = "123456")
//    @NotNull(message = "渠道编号不能为空")
//    private String bookingKey;
//
//    @Schema(description = "预定参数加密串（白屏来源订单必填）", requiredMode = Schema.RequiredMode.REQUIRED, example = "123456")
//    @NotNull(message = "渠道编号不能为空")
//    private String bookingSecret;
//
//    @Schema(description = "联系人手机", example = "123456")
//    @NotNull(message = "联系人手机不能为空")
//    private String contactMobile;
//
//    @Valid
//    @Schema(description = "行程信息", requiredMode = Schema.RequiredMode.REQUIRED, example = "[]")
//    @NotEmpty(message = "行程信息不能为空")
//    private List<AirOrderRouteCreateReqDTO> routes;
//
//    @Valid
//    @Schema(description = "乘客信息", requiredMode = Schema.RequiredMode.REQUIRED)
//    @NotEmpty(message = "乘客信息不能为空")
//    private List<AirOrderPassengerCreateReqDTO> passengers;
}
